/*
 * @lc app=leetcode.cn id=2215 lang=typescript
 *
 * [2215] 找出两数组的不同
 */

// @lc code=start
function findDifference(nums1: number[], nums2: number[]): number[][] {
    return [
        [...new Set(nums1.filter((i) => !nums2.includes(i)))],
        [...new Set(nums2.filter((i) => !nums1.includes(i)))],
    ];
}
// @lc code=end
